import { createRouter, createWebHistory } from 'vue-router'
import DemoView from '@/views/DemoView.vue'
import IconDemo from '@/views/demos/IconDemo.vue'
import DrawingPanelDemo from '@/views/demos/DrawingPanelDemo.vue'
import SearchBarDemo from '@/views/demos/SearchBarDemo.vue'
import TxView from '@/views/TxView.vue'
import GoodsCardDemo from '@/views/demos/GoodsCardDemo.vue'
import GoodsListDemo from '@/views/demos/GoodsListDemo.vue'
import AfastTreeDemo from '@/views/demos/AfastTreeDemo.vue'
const router = createRouter({
  history: createWebHistory('/'),
  routes: [
    {
      path: '/demo',
      name: 'demo',
      component: DemoView,
      children: [
        {
          path: '/demo-icons',
          name: 'demo-icons',
          component: IconDemo
        },
        {
          path: '/demo-card',
          name: 'demo-card',
          component: TxView
        }, {
          path: '/demo-draw',
          name: 'demo-draw',
          component: DrawingPanelDemo
        }, {
          path: '/demo-search-bar-draw',
          name: 'demo-search-bar-draw',
          component: SearchBarDemo
        }, {
          path: '/demo-goods-card',
          name: 'demmo-goods-card',
          component: GoodsCardDemo
        }, {
          path: '/demo-goods-list',
          name: 'demmo-goods-list',
          component: GoodsListDemo
        },{
          path: '/demo-tree',
          name: 'demmo-tree',
          component: AfastTreeDemo
        }
      ]
    },
  ]
})

export default router
